There have been event distribution systems that can distribute data composed of a plurality of attributes such as an ID, a position, and a time (hereinafter referred to as “event”) to applications. An event is composed of at least one attribute. An attribute is composed of an attribute name and an attribute value. For example, when an event is generated based on a temperature of 20° C. and a humidity of 60% measured by a temperature/humidity sensor, the event may be expresses as being composed of an attribute whose attribute name is “temperature” and whose attribute value is 20° C. and an attribute whose attribute name is “humidity” and whose attribute value is 60%.
A subscription ID, a request type, and a subscription are input (subscribed) from an external program (subscriber) to the event distribution system. The subscription ID is information used to identify the subscription. The request type is information used to determine whether it is a registration request or a deletion request. A subscription is composed of a condition of an event (event condition) and an ID of an application at the destination (application ID). In the case of the registration request, a pair of a subscription ID and a subscription is stored in the event distribution system.
When an event occurs, the occurring event is input (published) from an external program (publisher) to the event distribution system. When the event conforms to the event condition of a subscription in which the event is registered, the event distribution system transmits that event to an application identified by an application ID that is designated as being paired with the event condition.
A plurality of attribute conditions can be described as an event condition. An attribute name and a range of an attribute value for the attribute name can be specified as an attribute condition. When an event satisfies such a condition that, for each of all the attribute conditions constituting an event condition, the event includes an attribute name specified by the attribute condition and the range of an attribute value specified by the attribute condition covers an attribute value for the attribute name described in the event, then this means that the event conforms to the event condition. For example, assume that an event condition that an attribute name is “temperature” and the range of an attribute value for the attribute name is “no lower than 10° C. and no higher than 30° C.” is registered in the event distribution system. In this state, assume also that an event including an attribute whose attribute name is “temperature” and whose attribute value is “20° C.” and an attribute whose attribute name is “humidity” and whose attribute value is “60%” occurs. As for the attribute name “temperature” specified in the event condition, “20° C.” is within the range “no lower than 10° C. and no higher than 30° C”. Therefore, this means that the event conforms to the event condition. As for the attribute name “humidity”, it is not specified in the event condition. Therefore, it has no effect on whether the event conforms to the event condition or not.
Non-patent literature 1 discloses an example of a technique for processing an event like the one described above. FIG. 19 is a diagram for explaining the technique disclosed in Non-patent literature 1. Each of the event (publication in FIG. 19) and the event condition (subscription in FIG. 19) shown in FIG. 19 is composed of an attribute name x and an attribute name y. In the event, it is described that an attribute value for the attribute name x is 100 and an attribute value for the attribute name y is 200. In the event condition, it is described that the range of an attribute value for the attribute name x is “no less than 50 and no greater than 150” and the range of an attribute value for the attribute name y is “no less than 150 and no greater than 250”. The event conforms to the event condition.
The system shown in FIG. 19 is composed of sub systems (hubs) that correspond to the respective attribute names in a one-to-one relation. A hub includes at least one node configured in a ring shape. When viewed from a given node, the next node on the ring is called “successor”. Each node belonging to a hub manages the range of an attribute value (attribute value range) for an attribute name corresponding to the hub.
When a node receives a subscription from a subscriber or an event from a publisher, the node transfers the event or the subscription to a node that belongs to a different hub from the one to which the node belongs. Therefore, a node holds the network address of a node that belongs to a different hub from the one to which the node belongs (hereinafter, the node like this is called “cross-hub adjacent node”). Non-patent literature 2 discloses a method for determining a cross-hub adjacent node.
When a new node joins in a hub, the cross-hub adjacent node of the successor of that node is linked to the cross-hub adjacent node of that node. After that, a maintenance process is started. In the maintenance process, a new cross-hub adjacent node is determined by carrying out random walk in each of the other hubs. The random walk means a process in which: an access (hop) is performed from a node from which the random walk is started to an arbitrary node recoded in a routing table; a hop is further performed from the accessed node to another node through the same procedure described above; and the hop is repeated until the number of hops reaches a predetermined number. Further, a node that is accessed when the number of hops reaches the predetermined number is determined as a cross-hub adjacent node.